Skip to content

Reformatted standalone policy files with cfengine format#3675

Open
olehermanse wants to merge 2 commits into
cfengine:masterfrom
olehermanse:master
Open

Reformatted standalone policy files with cfengine format#3675
olehermanse wants to merge 2 commits into
cfengine:masterfrom
olehermanse:master

Conversation

@olehermanse
Copy link
Copy Markdown
Member

No description provided.

@olehermanse
Copy link
Copy Markdown
Member Author

@cf-bottom jenkins, please

@cf-bottom
Copy link
Copy Markdown

Signed-off-by: Ole Herman Schumacher Elgesem <ole@northern.tech>
Signed-off-by: Ole Herman Schumacher Elgesem <ole@northern.tech>
@olehermanse olehermanse changed the title cfengine format Reformatted standalone policy files with cfengine format Jun 1, 2026
@olehermanse olehermanse requested review from craigcomstock and nickanderson and removed request for craigcomstock June 1, 2026 23:08
@olehermanse olehermanse marked this pull request as ready for review June 1, 2026 23:08
@olehermanse
Copy link
Copy Markdown
Member Author

@cf-bottom jenkins, please

@cf-bottom
Copy link
Copy Markdown

Copy link
Copy Markdown
Contributor

@craigcomstock craigcomstock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand that comment placement is tricky so am approving this PR even though I found several places that seem to need more work to transition from old policy to formatted policy with comments.

Comment on lines +41 to +45
when_no_source => "force";
# kill
link_children => "true";
when_linking_children => "if_no_such_file";
# "override_file";
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these comments probably should be ABOVE the line they are commenting on or transformed into a comment attribute. I bet you handled this in a subsequent commit :)

Comment on lines +261 to +262
# };
"accounts_to_delete" -> {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there should probably be a gap here or delete the commented out code or ???

Comment on lines +535 to +536
# perms => mog("755","root","root");
"/etc/rc.d/init.d" -> {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a gap here?

Comment on lines +891 to +903
# "/etc/hosts.allow" -> { "GEN006620" }
# comment => "CAT II UNIX STIG: 6.6 Access Control Programs and TCP_WRAPPERS",
# handle => "stigs_files_redhat_5_etc_hosts_allow",
# edit_line => append_if_no_lines("@(stigs.hosts_allow)");
# "/etc/hosts.deny" -> { "GEN006620" }
# comment => "CAT II UNIX STIG: 6.6 Access Control Programs and TCP_WRAPPERS",
# handle => "stigs_files_redhat_5_etc_hosts_deny",
# edit_line => append_if_no_line("ALL: ALL");
# "/boot/grub/menu.lst" -> { "LNX00140" }
# comment => "CAT I (Previously - L072) UNIX STIG: 12.4.1.1 Password Protecting the GRUB Console Boot Loader",
# handle => "stigs_files_redhat_5_boot_grub_menu_lst",
# edit_line => maintain_grub;
"/boot/grub/grub.conf" -> { "LNX00160" }
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gaps should be here or re-organize somehow

Comment on lines +982 to +983
# usebundle => disabling_accounts("$(accounts_to_disable)");
"UNIX STIG 4.8/UNIX STIG 12.9" -> {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

used to be a gap here, probably should still be some separation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

3 participants